package com.erp.programmer.dto;

import com.erp.programmer.annotation.ValidateEntity;
import com.fasterxml.jackson.annotation.JsonFormat;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * @Author: Takagi3
 * @QQ: 870089046
 * @VX: HandsomeMY_
 * @Date: create in 2021/5/24 19:16
 */
public class SaleOrderDto {
    //"销售订单编号"  自动生成，不需验证
    private String id;

    //"客户公司ID"
    @ValidateEntity(required=true,requiredMaxLength=true,requiredMinLength=true,maxLength=19,minLength=19,errorRequiredMsg="卖方公司名称不能为空！",errorMaxLengthMsg="客户公司ID必须为19位！",errorMinLengthMsg="客户公司ID必须为19位！")
    private String clientCompanyId;

    private ClientCompanyDto clientCompanyDto;

    //"总价"
    private BigDecimal totalPrice;


    //"订单日期"
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date orderData;

    //"完成日期"
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date completeData;

    //"对应详单"
    private List<SaleOrderDetailDto> saleOrderDetailDtos;

    //搜索内容
    private String searchContent;

    //搜索类型
    private String searchType;
    //未付款1  已付款2
    private int paymentState;


    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getClientCompanyId() {
        return clientCompanyId;
    }

    public void setClientCompanyId(String clientCompanyId) {
        this.clientCompanyId = clientCompanyId;
    }



    public BigDecimal getTotalPrice() {
        return totalPrice;
    }

    public void setTotalPrice(BigDecimal totalPrice) {
        this.totalPrice = totalPrice;
    }

    public Date getOrderData() {
        return orderData;
    }

    public void setOrderData(Date orderData) {
        this.orderData = orderData;
    }

    public Date getCompleteData() {
        return completeData;
    }

    public void setCompleteData(Date completeData) {
        this.completeData = completeData;
    }

    public String getSearchContent() {
        return searchContent;
    }

    public void setSearchContent(String searchContent) {
        this.searchContent = searchContent;
    }

    public String getSearchType() {
        return searchType;
    }

    public void setSearchType(String searchType) {
        this.searchType = searchType;
    }


    public List<SaleOrderDetailDto> getSaleOrderDetailDtos() {
        return saleOrderDetailDtos;
    }

    public void setSaleOrderDetailDtos(List<SaleOrderDetailDto> saleOrderDetailDtos) {
        this.saleOrderDetailDtos = saleOrderDetailDtos;
    }

    public int getPaymentState() {
        return paymentState;
    }

    public void setPaymentState(int paymentState) {
        this.paymentState = paymentState;
    }

    public ClientCompanyDto getClientCompanyDto() {
        return clientCompanyDto;
    }

    public void setClientCompanyDto(ClientCompanyDto clientCompanyDto) {
        this.clientCompanyDto = clientCompanyDto;
    }
}

